From: Ray Strode Date: Tue, 28 Jun 2011 12:57:19 +0000 (-0400) Subject: dateMenu: Force min-width of events area, not whole menu X-Git-Tag: archive/raspbian/50.5-1+rpi1~1^2~1013^2^2~7883 X-Git-Url: https://dgit.raspbian.org/%22http://www.example.com/cgi/%22/%22http:/www.example.com/cgi/%22?a=commitdiff_plain;h=5be9326192f60143d55a327784aa78f9a9ce46ae;p=gnome-shell.git dateMenu: Force min-width of events area, not whole menu The theme currently hard codes the minimum size of the calendar menu to make sure there's a designated area for events (even if there isn't anything currently scheduled). A side-effect of the hard coded minimum width is that if the events area is hidden, the menu ends up much bigger than the calendar. We don't currently ever hide the events area, but we will in the future. This commit moves the min-width restriction from the menu specifically to the events area. https://bugzilla.gnome.org/show_bug.cgi?id=657082 --- diff --git a/data/theme/gnome-shell.css b/data/theme/gnome-shell.css index 8d112f1c3..a2c832fff 100644 --- a/data/theme/gnome-shell.css +++ b/data/theme/gnome-shell.css @@ -836,9 +836,9 @@ StTooltip StLabel { /* Calendar popup */ -#calendarArea { - /* this is the width of the entire popup */ - min-width: 600px; +#calendarEventsArea { + /* this is the width of the second column of the popup */ + min-width: 400px; } .calendar-vertical-separator { diff --git a/js/ui/dateMenu.js b/js/ui/dateMenu.js index 4a4b10323..1855c3a54 100644 --- a/js/ui/dateMenu.js +++ b/js/ui/dateMenu.js @@ -61,7 +61,7 @@ DateMenuButton.prototype = { this._clock = new St.Label(); this.actor.set_child(this._clock); - hbox = new St.BoxLayout({name: 'calendarArea'}); + hbox = new St.BoxLayout({name: 'calendarArea' }); this.menu.addActor(hbox); // Fill up the first column @@ -101,8 +101,8 @@ DateMenuButton.prototype = { hbox.add(item); // Fill up the second column - - vbox = new St.BoxLayout({vertical: true}); + vbox = new St.BoxLayout({name: 'calendarEventsArea', + vertical: true}); hbox.add(vbox, { expand: true }); // Event list